// vite.config.ts
import { resolve as resolve2 } from "path";

// config/index.ts
import { resolve } from "path";
import vue from "file:///D:/graduate_first/graduate_items/graduate_oj_vue/node_modules/@vitejs/plugin-vue/dist/index.mjs";
import svgLoader from "file:///D:/graduate_first/graduate_items/graduate_oj_vue/node_modules/vite-svg-loader/index.js";
import vueJsx from "file:///D:/graduate_first/graduate_items/graduate_oj_vue/node_modules/@vitejs/plugin-vue-jsx/dist/index.mjs";
import removeConsole from "file:///D:/graduate_first/graduate_items/graduate_oj_vue/node_modules/vite-plugin-remove-console/dist/index.mjs";
import VueI18nPlugin from "file:///D:/graduate_first/graduate_items/graduate_oj_vue/node_modules/@intlify/unplugin-vue-i18n/lib/vite.mjs";

// config/plugin/compress.ts
import compressPlugin from "file:///D:/graduate_first/graduate_items/graduate_oj_vue/node_modules/vite-plugin-compression/dist/index.mjs";
function configCompressPlugin(compress, deleteOriginFile = false) {
  const plugins = [];
  if (compress === "gzip") {
    plugins.push(
      compressPlugin({
        ext: ".gz",
        deleteOriginFile
      })
    );
  }
  if (compress === "brotli") {
    plugins.push(
      compressPlugin({
        ext: ".br",
        algorithm: "brotliCompress",
        deleteOriginFile
      })
    );
  }
  return plugins;
}

// config/plugin/visualizer.ts
import visualizer from "file:///D:/graduate_first/graduate_items/graduate_oj_vue/node_modules/rollup-plugin-visualizer/dist/plugin/index.js";
function configVisualizerPlugin(lifecycle) {
  if (lifecycle === "report") {
    return visualizer({
      filename: "./node_modules/.cache/visualizer/stats.html",
      open: true,
      gzipSize: true,
      brotliSize: true
    });
  }
  return null;
}

// config/plugin/autoImport.ts
import AutoImport from "file:///D:/graduate_first/graduate_items/graduate_oj_vue/node_modules/unplugin-auto-import/dist/vite.js";
import Components from "file:///D:/graduate_first/graduate_items/graduate_oj_vue/node_modules/unplugin-vue-components/dist/vite.js";
import { ArcoResolver } from "file:///D:/graduate_first/graduate_items/graduate_oj_vue/node_modules/unplugin-vue-components/dist/resolvers.js";
function autoImportPlugin() {
  return [
    AutoImport({
      imports: [],
      resolvers: [ArcoResolver()],
      dts: "./src/types/auto-imports.d.ts"
    }),
    Components({
      extensions: ["vue"],
      resolvers: [
        ArcoResolver({
          resolveIcons: false
        })
      ],
      dts: "./src/types/components.d.ts"
    })
  ];
}

// config/index.ts
function pluginsList() {
  return [
    vue(),
    autoImportPlugin(),
    VueI18nPlugin({
      runtimeOnly: true,
      compositionOnly: true,
      include: [resolve("locales/**")]
    }),
    vueJsx(),
    // jsx支持
    removeConsole(),
    // 移除console
    svgLoader({ svgoConfig: {} }),
    // svg组件化支持
    configCompressPlugin("gzip"),
    // 压缩
    configVisualizerPlugin("none")
    // 打包分析
  ];
}

// vite.config.ts
import { loadEnv } from "file:///D:/graduate_first/graduate_items/graduate_oj_vue/node_modules/vite/dist/node/index.js";
import autoprefixer from "file:///D:/graduate_first/graduate_items/graduate_oj_vue/node_modules/autoprefixer/lib/autoprefixer.js";
import tailwindcss from "file:///D:/graduate_first/graduate_items/graduate_oj_vue/node_modules/tailwindcss/lib/index.js";
var __vite_injected_original_dirname = "D:\\graduate_first\\graduate_items\\graduate_oj_vue";
var vite_config_default = ({ mode }) => {
  const { VITE_PORT, VITE_BASE } = loadEnv(mode, process.cwd());
  return {
    base: VITE_BASE,
    // 路径别名
    resolve: {
      alias: {
        "@": resolve2(__vite_injected_original_dirname, "src"),
        "assets": resolve2(__vite_injected_original_dirname, "src/assets"),
        "vue": "vue/dist/vue.esm-bundler.js"
        // compile template
      }
    },
    css: {
      postcss: {
        plugins: [tailwindcss, autoprefixer]
      },
      preprocessorOptions: {
        less: {
          modifyVars: {
            hack: `true; @import (reference) "${resolve2(
              "src/assets/style/variables.less"
            )}";`
          },
          // https://lesscss.org/usage/#less-options
          math: "parens-division",
          javascriptEnabled: true
        }
      }
    },
    plugins: [pluginsList()],
    // 依赖预构建-> https://cn.vitejs.dev/config/dep-optimization-options#dep-optimization-options
    optimizeDeps: {
      include: ["mitt", "dayjs", "axios", "pinia", "@vueuse/core", "vue-i18n"],
      exclude: ["@iconify-icons/lets-icons"]
    },
    server: {
      // 允许跨域
      cors: true,
      // 监听所有地址
      host: "0.0.0.0",
      // 服务启动时是否自动打开浏览器
      open: false,
      // 端口号（这里使用了变量 VITE_PORT）
      port: Number(VITE_PORT),
      // 本地跨域代理-> 代理到服务器的接口地址
      proxy: {
        "/api": {
          target: "http://localhost:8101",
          changeOrigin: true,
          ws: true
        }
      },
      // 预热文件以降低启动期间的初始页面加载时长
      warmup: {
        // 预热的客户端文件：首页、views、 components
        clientFiles: ["./index.html", "./src/{views,components}/*"]
      }
    },
    build: {
      // 浏览器兼容目标
      target: "es2015",
      // 是否生成 source map 文件
      sourcemap: false,
      rollupOptions: {
        output: {
          entryFileNames: "static/js/[name]-[hash].js",
          chunkFileNames: "static/js/[name]-[hash].js",
          assetFileNames: "static/[ext]/[name]-[hash].[ext]",
          compact: true,
          // 自定义 chunk
          manualChunks: {
            arco: ["@arco-design/web-vue"],
            chart: ["echarts", "vue-echarts"],
            vue: ["vue", "vue-router", "pinia", "@vueuse/core", "vue-i18n"]
          }
        }
      },
      // chunk 大小警告的限制
      chunkSizeWarningLimit: 2e3
    }
  };
};
export {
  vite_config_default as default
};
//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsidml0ZS5jb25maWcudHMiLCAiY29uZmlnL2luZGV4LnRzIiwgImNvbmZpZy9wbHVnaW4vY29tcHJlc3MudHMiLCAiY29uZmlnL3BsdWdpbi92aXN1YWxpemVyLnRzIiwgImNvbmZpZy9wbHVnaW4vYXV0b0ltcG9ydC50cyJdLAogICJzb3VyY2VzQ29udGVudCI6IFsiY29uc3QgX192aXRlX2luamVjdGVkX29yaWdpbmFsX2Rpcm5hbWUgPSBcIkQ6XFxcXGdyYWR1YXRlX2ZpcnN0XFxcXGdyYWR1YXRlX2l0ZW1zXFxcXGdyYWR1YXRlX29qX3Z1ZVwiO2NvbnN0IF9fdml0ZV9pbmplY3RlZF9vcmlnaW5hbF9ma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